package Loganseabolt;

import Loganseabolt.blocks.Horseman_Block;
import Loganseabolt.blocks.TomatoCrop;
import Loganseabolt.tools.TomatoSeeds;
import scala.languageFeature;



import net.minecraftforge.common.AchievementPage;
import net.minecraftforge.common.EnumHelper;
import net.minecraftforge.common.MinecraftForge;
import net.minecraftforge.common.ForgeHooks;
import cpw.mods.fml.common.Mod;
import cpw.mods.fml.common.Mod.Init;
import cpw.mods.fml.common.Mod.Instance;
import cpw.mods.fml.common.Mod.PostInit;
import cpw.mods.fml.common.Mod.PreInit;
import cpw.mods.fml.common.SidedProxy;
import cpw.mods.fml.common.event.FMLInitializationEvent;
import cpw.mods.fml.common.event.FMLPostInitializationEvent;
import cpw.mods.fml.common.event.FMLPreInitializationEvent;
import cpw.mods.fml.common.network.NetworkMod;
import cpw.mods.fml.common.registry.GameRegistry;
import cpw.mods.fml.common.registry.LanguageRegistry;
import events.HorseEvent2;
import events.HorsemanEvent;
import net.minecraft.block.Block;
import net.minecraft.block.material.Material;
import net.minecraft.creativetab.CreativeTabs;
import net.minecraft.item.EnumArmorMaterial;
import net.minecraft.item.EnumToolMaterial;
import net.minecraft.item.Item;
import net.minecraft.item.ItemSeeds;
import net.minecraft.item.ItemStack;
import net.minecraft.potion.Potion;
import net.minecraft.stats.Achievement;
import net.minecraft.stats.AchievementList;

@Mod(modid = "LoganSeaboltModBase", name = "LoganSeaboltModBase", version = "0.0.0")
@NetworkMod(clientSideRequired = true, serverSideRequired = false)
public class LoganSeaboltModBase 
{
	
	@Instance("LoganSeaboltModBase")
	public static LoganSeaboltModBase instance;
	@SidedProxy(clientSide="Loganseabolt.ClientProxy", serverSide="Loganseabolt.CommonProxy")
	public static CommonProxy proxy;
	
	static EnumArmorMaterial Wars_AR = EnumHelper.addArmorMaterial("Wars Armor", 25, new int[]{3, 10, 6, 3}, 22);
	
	public static Item Logan2= new Loganseabolt.tools.Logan2(500).setUnlocalizedName("Blarg");
	public static Item Grass_Sword= new Loganseabolt.weapons.Grass_Sword(501, EnumToolMaterial.GOLD).setUnlocalizedName("Killer Bunny");
	public static Item Grass_Bow= new Loganseabolt.weapons.Grass_Bow(502).setUnlocalizedName("Fishslap");
	public static Item Grass_Arrow= new Loganseabolt.weapons.Grass_Arrow(503).setUnlocalizedName("Spam");
	public static Item MEDIC= new Loganseabolt.weapons.MEDIC(504, EnumToolMaterial.EMERALD).setUnlocalizedName("Spamier");;
	public static Item Furys_Gun= new Loganseabolt.weapons.Furys_Gun(505).setUnlocalizedName("Ni");
	public static Item Holy_HandG= new Loganseabolt.weapons.Holy_HandG(506).setUnlocalizedName("HOLY HAND GRENADE OF ANTIOCH");
	public static Item Souls= new Loganseabolt.tools.Soul(514).setUnlocalizedName("SOULS");
	public static Item Dirty_Leather= new Loganseabolt.tools.Dirty_Leather(508).setUnlocalizedName("Eckky");
	public static Item Death_Scycthe= new Loganseabolt.weapons.Death_Scycthe(509, EnumToolMaterial.EMERALD).setUnlocalizedName("Ecckky");
	public static Item Hammer= new Loganseabolt.weapons.Hammer(519, EnumToolMaterial.EMERALD).setUnlocalizedName("hamm"); 
	public static Item HMI= new Loganseabolt.weapons.HMI(510).setUnlocalizedName("Ptkang");
	public static Item War_sword= new Loganseabolt.weapons.War_Sword(513, EnumToolMaterial.EMERALD).setUnlocalizedName("Spamiest");
	public static Item Tomato= new Loganseabolt.tools.Tomato(518, 4, 1.2f, false).setAlwaysEdible().setUnlocalizedName("GG");
	public static Item QuickBaseWand = new Loganseabolt.tools.wand_o_Dia(521, EnumToolMaterial.STONE).setUnlocalizedName("QuickBaseWandl");
	public final static Block tomatoCrop = new TomatoCrop(502).setUnlocalizedName("TomatoCrop");
	public final static ItemSeeds tomatoSeeds = (ItemSeeds)new TomatoSeeds(520, tomatoCrop.blockID, Block.tilledField.blockID).setUnlocalizedName("seeds.tomato");
	public static Item WarH;// = new com.addeditems.helmetSuper(632, War_AR, proxy.addArmor("War_AR"), 0).setUnlocalizedName("helmetSuper");
    public static Item WarC;// = new com.addeditems.chestplateSuper(633, War_AR, proxy.addArmor("War_AR"), 1).setUnlocalizedName("chestplateSuper");
    public static Item WarL;// = new com.addeditems.legsSuper(634, War_AR, proxy.addArmor("War_AR"), 2).setUnlocalizedName("legsSuper");
    public static Item WarB;// = new com.addeditems.bootsSuper(635, War_AR, proxy.addArmor("War_AR"), 3).setUnlocalizedName("bootsSuper");

	
    public static Block Dia= new Loganseabolt.blocks.Dia(522, Material.anvil).setUnlocalizedName("DiaBlock");
	public static Block Mob_Spawner= new Loganseabolt.blocks.Mob_Spawners(511, Material.anvil).setUnlocalizedName("Zoom");
	public static Block itsa= new Loganseabolt.blocks.itsa(516, Material.glass, false).setUnlocalizedName("boing");
	public static Block HorseB= new Loganseabolt.blocks.Horseman_Block(515, Material.anvil).setUnlocalizedName("HPL");
	public static Block SoulO = new Loganseabolt.blocks.SoulO(517).setUnlocalizedName("oreSoul");
	public static Block Enriched_Grass= new Loganseabolt.blocks.Enriched_Grass(507).setUnlocalizedName("Ecky");
	
	
	public static final Achievement theApoc = new Achievement(2001, "theApoc", -1, 3, HMI, AchievementList.diamonds).setSpecial().registerAchievement();
	public static final Achievement WAR = new Achievement(2002, "WAR", -1, 1, War_sword, LoganSeaboltModBase.theApoc).setSpecial().registerAchievement();
	public static AchievementPage page1 = new AchievementPage("Horseman Achivements", theApoc, WAR);
	@PreInit
	public void preInit(FMLPreInitializationEvent event)
	{
	}
	@Init
	public void load(FMLInitializationEvent event)
	{
		
		//MinecraftForge.
		WarH = (Item)new Loganseabolt.Wars_AR(526, Wars_AR, proxy.addArmor("Wars Armor"), 0).setUnlocalizedName("WH");
        
        WarC = new Loganseabolt.Wars_AR(525, Wars_AR, proxy.addArmor("Wars Armor"), 1).setUnlocalizedName("WC");
        
        WarL = new Loganseabolt.Wars_AR(524, Wars_AR, proxy.addArmor("Wars Armor"), 2).setUnlocalizedName("WL");
        
        WarB = new Loganseabolt.Wars_AR(523, Wars_AR, proxy.addArmor("Wars Armor"), 3).setUnlocalizedName("WB");
		
        util.recipe();
		GameRegistry.registerWorldGenerator(new WorldGen());
		LanguageRegistry.instance().addStringLocalization("achievement.theApoc", "en_US", "The Apocalypse");
		LanguageRegistry.instance().addStringLocalization("achievement.theApoc.desc", "en_US", "It's coming");
		LanguageRegistry.instance().addStringLocalization("achievement.WAR", "en_US", "War");
		LanguageRegistry.instance().addStringLocalization("achievement.WAR.desc", "en_US", "No, Not Alone.");
		
		
		LanguageRegistry.addName(Logan2, "Super XP Potion");
		LanguageRegistry.addName(Grass_Sword, "Grassy Sword");
		LanguageRegistry.addName(Grass_Bow, "Grassy Bow");
		LanguageRegistry.addName(Grass_Arrow, "Grass Arrow");
		LanguageRegistry.addName(MEDIC, "Cross");
		LanguageRegistry.addName(Furys_Gun, "Conquest's Pistol");
		LanguageRegistry.addName(Holy_HandG, "Holy Hand Grenade of Antioch");
		LanguageRegistry.addName(Enriched_Grass, "Enriched Grass");
		LanguageRegistry.addName(Death_Scycthe, "Death's Scythe");
		LanguageRegistry.addName(HMI, "Horsemans Ingot");
		LanguageRegistry.addName(War_sword, "Chaoseater");
		LanguageRegistry.addName(Dirty_Leather, "Dirty Leather");
		LanguageRegistry.addName(Hammer, "Conquest's Hammer");
		LanguageRegistry.addName(Tomato, "Tomato");
		LanguageRegistry.addName(tomatoSeeds, "Tomato Seed");
		LanguageRegistry.addName(QuickBaseWand, "Wand of Diamonds");
		LanguageRegistry.addName(Mob_Spawner, "Arena Starter");
		LanguageRegistry.addName(SoulO, "Soul Ore");
		LanguageRegistry.addName(WarH, "War's Helmet");
		LanguageRegistry.addName(WarC, "War's Chestplate");
		LanguageRegistry.addName(WarB, "War's Boots");
		LanguageRegistry.addName(WarL, "War's Leggings");
		LanguageRegistry.addName(HorseB, "Block of Horseman Ingots");
		LanguageRegistry.addName(Souls, "Soul of the Dammned");
		LanguageRegistry.addName(itsa, "Horseman Seal");
		LanguageRegistry.addName(Dia, "Dia Block (diamonds?)");
		
		
		GameRegistry.registerBlock(Enriched_Grass);
		GameRegistry.registerBlock(SoulO, SoulO.getUnlocalizedName());
		GameRegistry.registerBlock(Mob_Spawner);
		GameRegistry.registerBlock(Dia);
		GameRegistry.registerBlock(itsa);
		GameRegistry.registerBlock(HorseB);
		
		
		GameRegistry.registerCraftingHandler(new HorsemanEvent());
		GameRegistry.registerCraftingHandler(new HorseEvent2());
		AchievementPage.registerAchievementPage(page1);
		//GameRegistry.reg
	}
	@PostInit 
	public void postInit(FMLPostInitializationEvent event)
	{
	}
}
